<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8" >
    <title>1</title>
    <link rel="stylesheet" href="bootstrap/css/bootstrap.min.css" />
    <link rel="stylesheet" href="bootstrap/css/bootstrap-theme.css" />
</head>




<div class="container">
    <div class="row" th:insert="public.html :: head"></div>
    <!--顶部导航-->
    <div class="row" th:insert="public.html :: public_top">
    </div>
    <br />
    <!--内容-->
    <div class="row">
        <div class="col-sm-2" th:insert="public.html :: public_left_student">
        </div>
        <div class="col-xs-9 col-md-10">
            <table border="1" class="table table-striped">
                <tr>
                    <th><b>id</b></th>
                    <th>名字</th>
                    <th>密码</th>
                    <th>性别</th>
                    <th>班级</th>
                    <th>生日</th>
                    <th>头像</th>
                    <th>scores</th>
                    <th>编辑</th>
                </tr>
                <tbody th:remove="all-but-first">
                <tr th:each="student : ${students}">
                    <th th:text="${student.id}"></th>
                    <th th:text="${student.name}"></th>
                    <th th:text="${student.password}"></th>
                    <th th:text="${student.sex}"></th>
                    <th th:text="${student.clazz}"></th>
                    <th th:text="${student.birthday}"></th>

                </tr>
                </tbody>
            </table>

            <div class="row">
                <div class="col-md-12">
                </div>

                <div class="col-md-12">

                    <nav aria-label="Page navigation example">
                        <ul class="pagination pagination-sm">
                            <li class="page-item"><a class="page-link" href="list.do?page=1">首页</a></li>
                            <th:if test="${pageInfo.hasPreviousPage}">
                                <li class="page-item"><a class="page-link"
                                                         href="list.do?page=${pageInfo.pageNum-1}">上一页</a></li>
                            </th:if>
                            <th:each items="${pageInfo.navigatepageNums}" var="page">
                                <th:if test="${page==pageInfo.pageNum}">
                                    <li class="page-item active"><a class="page-link" href="#">确定</a></li>
                                </th:if>
                                <th:if test="${page!=pageInfo.pageNum}">
                                    <li class="page-item"><a class="page-link"
                                                             href="list.do?page=${page}">${page}</a></li>
                                </th:if>
                            </th:each>
                            <th:if test="${pageInfo.hasNextPage}">
                                <li class="page-item"><a class="page-link"
                                                         href="list.do?page=${pageInfo.pageNum+1}">下一页</a></li>
                            </th:if>
                            <li class="page-item"><a class="page-link" href="list.do?page=${pageInfo.pages}">末页</a>
                            </li>
                        </ul>
                    </nav>
                </div>

            </div>
        </div>


        <script type="text/javascript" src="bootstrap/js/jquery-3.3.1.min.js"></script>
        <script type="text/javascript" src="bootstrap/js/bootstrap.min.js"></script>

        </body>

</html>